package com.linln.admin.product.validator;

import lombok.Data;

import java.io.Serializable;
import javax.validation.constraints.Digits;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;

/**
 * @author Hamsun
 * @date 2020/04/22
 */
@Data
public class ProductValid implements Serializable {
    @NotEmpty(message = "产品名字不能为空")
    private String product_Name;
    @NotNull(message = "价格不能为空")
    @Digits(integer = 12, fraction = 2, message = "价格不是数字")
    private Double price;
    @NotEmpty(message = "产品状态不能为空")
    private String on_Sale;
}